package com.library.book.controller;

public class BookController {

    private BookInfoService bookInfoService;

    private TypeInfoService typeInfoService;

    public String bookIndex(){
        return "book/bookIndex";
    }
    
    public String bookAdd(){
        return "book/bookAdd";
    }

    public DataInfo addBookSubmit(BookInfo info){
        bookInfoService.addBookSubmit(info);
        return DataInfo.ok();
    }

    public DataInfo updateBookSubmit(@RequestBody BookInfo info){
        bookInfoService.updateBookSubmit(info);
        return DataInfo.ok();
    }
}
